import request from '@/utils/request'

// 查询生产厂家
export function fetchFactureList(id, name, pageIndex, pageSize) {
  return request({
    url: '/masterdata/maManufacturerunit/queryList',
    method: 'get',
    params: {
      id,
      name,
      pageIndex,
      pageSize
    },
    port: { ENV_PORT: 8003 },
    ajaxType2: 'reqGet'

  })
}

// 查询生产厂家详情
export function fetchFactureDetail(id) {
  return request({
    url: '/masterdata/maManufacturerunit/detail',
    method: 'get',
    params: { id },
    port: { ENV_PORT: 8003 },
    ajaxType2: 'reqGet'

  })
}

// //添加生产厂家
export function createFactureAdd(data) {
  return request({
    url: '/masterdata/maManufacturerunit/add',
    method: 'post',
    params: {},
    data: data,
    port: { ENV_PORT: 8003 },
    ajaxType2: 'reqPost'

  })
}

// 修改生产厂家
export function factureUpdate(data) {
  return request({
    url: '/masterdata/maManufacturerunit/update',
    method: 'put',
    params: {},
    data: data,
    port: { ENV_PORT: 8003 },
    ajaxType2: 'reqPut'

  })
}

// 删除生产厂家
export function factureDelete(id) {
  return request({
    url: '/masterdata/maManufacturerunit/delete',
    method: 'delete',
    params: { id },
    port: { ENV_PORT: 8003 },
    ajaxType2: 'reqDelete'

  })
}

